<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.8"/>
<title>KoldarCtester: macro/KoldarCTester.h File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="logo.png"/></td>
  <td style="padding-left: 0.5em;">
   <div id="projectname">KoldarCtester
   &#160;<span id="projectnumber">1.2</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.8 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
      <li><a href="globals.html"><span>Globals</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('KoldarCTester_8h.html','');});
</script>
<div id="doc-content">
<div class="header">
  <div class="summary">
<a href="#define-members">Macros</a>  </div>
  <div class="headertitle">
<div class="title">KoldarCTester.h File Reference</div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><code>#include &lt;stdbool.h&gt;</code><br />
<code>#include &lt;stdio.h&gt;</code><br />
<code>#include &lt;stdlib.h&gt;</code><br />
<code>#include &lt;string.h&gt;</code><br />
<code>#include &lt;limits.h&gt;</code><br />
</div><div class="textblock"><div class="dynheader">
Include dependency graph for KoldarCTester.h:</div>
<div class="dyncontent">
<div class="center"><img src="KoldarCTester_8h__incl.png" border="0" usemap="#macro_2KoldarCTester_8h" alt=""/></div>
</div>
</div>
<p><a href="KoldarCTester_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
Macros</h2></td></tr>
<tr class="memitem:a5f792115dc3f1978a91f1071e2fdb9d2"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a5f792115dc3f1978a91f1071e2fdb9d2">KCT_TESTSEPARATOR</a></td></tr>
<tr class="memdesc:a5f792115dc3f1978a91f1071e2fdb9d2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Represents the string that separates 2 test function in the output.  <a href="#a5f792115dc3f1978a91f1071e2fdb9d2">More...</a><br /></td></tr>
<tr class="separator:a5f792115dc3f1978a91f1071e2fdb9d2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a03d95195bbcbf6bf52e6c163281efed8"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a03d95195bbcbf6bf52e6c163281efed8">KCT_ERRORMESSAGE_EXPECTED</a></td></tr>
<tr class="memdesc:a03d95195bbcbf6bf52e6c163281efed8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Represents the string to print before the expected value in the error message.  <a href="#a03d95195bbcbf6bf52e6c163281efed8">More...</a><br /></td></tr>
<tr class="separator:a03d95195bbcbf6bf52e6c163281efed8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4c849806881e4b0a1db5d2ceb7f30fe8"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a4c849806881e4b0a1db5d2ceb7f30fe8">KCT_ERRORMESSAGE_ACTUAL</a></td></tr>
<tr class="memdesc:a4c849806881e4b0a1db5d2ceb7f30fe8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Represents the string to print before the actual value in the error message.  <a href="#a4c849806881e4b0a1db5d2ceb7f30fe8">More...</a><br /></td></tr>
<tr class="separator:a4c849806881e4b0a1db5d2ceb7f30fe8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a07e3e0722765c92ee10a9942dbbf7efb"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a07e3e0722765c92ee10a9942dbbf7efb">KCT_STRINGBUFFER</a></td></tr>
<tr class="separator:a07e3e0722765c92ee10a9942dbbf7efb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8b21af1302fae84b59f07b2b8964a64e"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a8b21af1302fae84b59f07b2b8964a64e">kct_addTestImproved</a>(function, torun)</td></tr>
<tr class="memdesc:a8b21af1302fae84b59f07b2b8964a64e"><td class="mdescLeft">&#160;</td><td class="mdescRight">adds a new function in the test list  <a href="#a8b21af1302fae84b59f07b2b8964a64e">More...</a><br /></td></tr>
<tr class="separator:a8b21af1302fae84b59f07b2b8964a64e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5e05020cd2cbf6ef54e4abb4c5d3ca57"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a5e05020cd2cbf6ef54e4abb4c5d3ca57">kct_addTest</a>(function)</td></tr>
<tr class="memdesc:a5e05020cd2cbf6ef54e4abb4c5d3ca57"><td class="mdescLeft">&#160;</td><td class="mdescRight">adds a new function in the test list  <a href="#a5e05020cd2cbf6ef54e4abb4c5d3ca57">More...</a><br /></td></tr>
<tr class="separator:a5e05020cd2cbf6ef54e4abb4c5d3ca57"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a410bf9dc82153e2f88b61ea9e360ab40"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a410bf9dc82153e2f88b61ea9e360ab40">kct_runAllTests</a>(outputfile)</td></tr>
<tr class="memdesc:a410bf9dc82153e2f88b61ea9e360ab40"><td class="mdescLeft">&#160;</td><td class="mdescRight">run all the test added to the test list.  <a href="#a410bf9dc82153e2f88b61ea9e360ab40">More...</a><br /></td></tr>
<tr class="separator:a410bf9dc82153e2f88b61ea9e360ab40"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4088943ed7c8cae2b853b402f29b4004"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a4088943ed7c8cae2b853b402f29b4004"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a4088943ed7c8cae2b853b402f29b4004">kct_fail</a>()</td></tr>
<tr class="memdesc:a4088943ed7c8cae2b853b402f29b4004"><td class="mdescLeft">&#160;</td><td class="mdescRight">Terminate the test and set the result of it as a failure. <br /></td></tr>
<tr class="separator:a4088943ed7c8cae2b853b402f29b4004"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a711828fbdf116ebd2722f9aa48916832"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a711828fbdf116ebd2722f9aa48916832">kct_failMsg</a>(message)</td></tr>
<tr class="memdesc:a711828fbdf116ebd2722f9aa48916832"><td class="mdescLeft">&#160;</td><td class="mdescRight">Terminate the test and set the result of it as a failure.  <a href="#a711828fbdf116ebd2722f9aa48916832">More...</a><br /></td></tr>
<tr class="separator:a711828fbdf116ebd2722f9aa48916832"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8497b72e092de90ddde2ebf2aad987ca"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a8497b72e092de90ddde2ebf2aad987ca"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a8497b72e092de90ddde2ebf2aad987ca">kct_ok</a>()</td></tr>
<tr class="memdesc:a8497b72e092de90ddde2ebf2aad987ca"><td class="mdescLeft">&#160;</td><td class="mdescRight">terminates successfully the current test <br /></td></tr>
<tr class="separator:a8497b72e092de90ddde2ebf2aad987ca"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab47b71b14664ccf62a03056bf6afd299"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#ab47b71b14664ccf62a03056bf6afd299">kct_assertCondition</a>(condition)</td></tr>
<tr class="memdesc:ab47b71b14664ccf62a03056bf6afd299"><td class="mdescLeft">&#160;</td><td class="mdescRight">end the test as a failure if the condition is <b>not</b> met  <a href="#ab47b71b14664ccf62a03056bf6afd299">More...</a><br /></td></tr>
<tr class="separator:ab47b71b14664ccf62a03056bf6afd299"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab8d7d3073507383a0ab0913ebdce4a10"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#ab8d7d3073507383a0ab0913ebdce4a10">kct_assertConditionMsg</a>(message, condition)</td></tr>
<tr class="memdesc:ab8d7d3073507383a0ab0913ebdce4a10"><td class="mdescLeft">&#160;</td><td class="mdescRight">end the test as a failure if the condition IS <b>not</b> met  <a href="#ab8d7d3073507383a0ab0913ebdce4a10">More...</a><br /></td></tr>
<tr class="separator:ab8d7d3073507383a0ab0913ebdce4a10"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a97bd5c75a68868a4e449fa6d2abd7bd8"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a97bd5c75a68868a4e449fa6d2abd7bd8">kct_assertNotCondition</a>(condition)</td></tr>
<tr class="memdesc:a97bd5c75a68868a4e449fa6d2abd7bd8"><td class="mdescLeft">&#160;</td><td class="mdescRight">end the test as a failure if the condition is met  <a href="#a97bd5c75a68868a4e449fa6d2abd7bd8">More...</a><br /></td></tr>
<tr class="separator:a97bd5c75a68868a4e449fa6d2abd7bd8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac1eb638d5f665bf8b99147c08db85788"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#ac1eb638d5f665bf8b99147c08db85788">kct_assertNotConditionMsg</a>(message, condition)</td></tr>
<tr class="memdesc:ac1eb638d5f665bf8b99147c08db85788"><td class="mdescLeft">&#160;</td><td class="mdescRight">end the test as a failure if the condition is met  <a href="#ac1eb638d5f665bf8b99147c08db85788">More...</a><br /></td></tr>
<tr class="separator:ac1eb638d5f665bf8b99147c08db85788"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0ce5dbaf8cd2f67f866855677b9dffa3"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a0ce5dbaf8cd2f67f866855677b9dffa3">kct_assertEqualStrMsg</a>(optmessage, expected, actual)</td></tr>
<tr class="memdesc:a0ce5dbaf8cd2f67f866855677b9dffa3"><td class="mdescLeft">&#160;</td><td class="mdescRight">tests if 2 strings are equal  <a href="#a0ce5dbaf8cd2f67f866855677b9dffa3">More...</a><br /></td></tr>
<tr class="separator:a0ce5dbaf8cd2f67f866855677b9dffa3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7ca6642a5313ed8f901d01503a41d971"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a7ca6642a5313ed8f901d01503a41d971">kct_assertEqualStr</a>(expected, actual)</td></tr>
<tr class="memdesc:a7ca6642a5313ed8f901d01503a41d971"><td class="mdescLeft">&#160;</td><td class="mdescRight">tests if 2 strings are equal  <a href="#a7ca6642a5313ed8f901d01503a41d971">More...</a><br /></td></tr>
<tr class="separator:a7ca6642a5313ed8f901d01503a41d971"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7c6235260c2f0889936b8edda762db19"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a7c6235260c2f0889936b8edda762db19">kct_assertEqualPrimitiveMsg</a>(message, type, conversion, expected, actual)</td></tr>
<tr class="memdesc:a7c6235260c2f0889936b8edda762db19"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if 2 simple values are equal. If not, send an error.  <a href="#a7c6235260c2f0889936b8edda762db19">More...</a><br /></td></tr>
<tr class="separator:a7c6235260c2f0889936b8edda762db19"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8b6f1bb142ced3a6d64d6cb08889bf77"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a8b6f1bb142ced3a6d64d6cb08889bf77">kct_assertNotEqualPrimitiveMsg</a>(message, type, conversion, expected, actual)</td></tr>
<tr class="memdesc:a8b6f1bb142ced3a6d64d6cb08889bf77"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if 2 simple values are not equal. If not, send an error.  <a href="#a8b6f1bb142ced3a6d64d6cb08889bf77">More...</a><br /></td></tr>
<tr class="separator:a8b6f1bb142ced3a6d64d6cb08889bf77"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af768219fd2cb4519ca0e547289ea8f07"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#af768219fd2cb4519ca0e547289ea8f07">kct_assertEqualStructMsg</a>(message, type, toStringFunction, compareFunction, expected, actual)</td></tr>
<tr class="memdesc:af768219fd2cb4519ca0e547289ea8f07"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if 2 structured data are equal. If not, send an error.  <a href="#af768219fd2cb4519ca0e547289ea8f07">More...</a><br /></td></tr>
<tr class="separator:af768219fd2cb4519ca0e547289ea8f07"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a42cb8f2498583663010902a2646b8d9d"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a42cb8f2498583663010902a2646b8d9d">kct_assertNotEqualStructMsg</a>(message, type, toStringFunction, compareFunction, expected, actual)</td></tr>
<tr class="memdesc:a42cb8f2498583663010902a2646b8d9d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if 2 structured data are different. If not, send an error.  <a href="#a42cb8f2498583663010902a2646b8d9d">More...</a><br /></td></tr>
<tr class="separator:a42cb8f2498583663010902a2646b8d9d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8438378dbf37f64bd50cc68b6c698dc1"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a8438378dbf37f64bd50cc68b6c698dc1">kct_assertEqualPtrMsg</a>(message, expected, actual)</td></tr>
<tr class="memdesc:a8438378dbf37f64bd50cc68b6c698dc1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if 2 pointers values are equal. If not, send an error.  <a href="#a8438378dbf37f64bd50cc68b6c698dc1">More...</a><br /></td></tr>
<tr class="separator:a8438378dbf37f64bd50cc68b6c698dc1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afb48d44aa30b8baab5acea013b5a13ea"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#afb48d44aa30b8baab5acea013b5a13ea">kct_assertNotEqualPtrMsg</a>(message, expected, actual)</td></tr>
<tr class="memdesc:afb48d44aa30b8baab5acea013b5a13ea"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if 2 pointer values are not equal. If not, send an error.  <a href="#afb48d44aa30b8baab5acea013b5a13ea">More...</a><br /></td></tr>
<tr class="separator:afb48d44aa30b8baab5acea013b5a13ea"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab4e6c61583ca8ac8951757b691081cdf"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#ab4e6c61583ca8ac8951757b691081cdf">kct_assertIsNotNull</a>(pointer)</td></tr>
<tr class="memdesc:ab4e6c61583ca8ac8951757b691081cdf"><td class="mdescLeft">&#160;</td><td class="mdescRight">test whether or not a pointer is NULL  <a href="#ab4e6c61583ca8ac8951757b691081cdf">More...</a><br /></td></tr>
<tr class="separator:ab4e6c61583ca8ac8951757b691081cdf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5264879a5a7bec99330e05bbc284460c"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a5264879a5a7bec99330e05bbc284460c">kct_assertIsNotNullMsg</a>(message, pointer)</td></tr>
<tr class="memdesc:a5264879a5a7bec99330e05bbc284460c"><td class="mdescLeft">&#160;</td><td class="mdescRight">test whether or not a pointer is NULL  <a href="#a5264879a5a7bec99330e05bbc284460c">More...</a><br /></td></tr>
<tr class="separator:a5264879a5a7bec99330e05bbc284460c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a336d48b62a9bb572ac9bdad71f180fdf"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a336d48b62a9bb572ac9bdad71f180fdf">kct_assertIsNull</a>(pointer)</td></tr>
<tr class="memdesc:a336d48b62a9bb572ac9bdad71f180fdf"><td class="mdescLeft">&#160;</td><td class="mdescRight">test whether or not a pointer is not NULL  <a href="#a336d48b62a9bb572ac9bdad71f180fdf">More...</a><br /></td></tr>
<tr class="separator:a336d48b62a9bb572ac9bdad71f180fdf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a453addaa537b7269312740f182c662d3"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a453addaa537b7269312740f182c662d3">kct_assertIsNullMsg</a>(message, pointer)</td></tr>
<tr class="memdesc:a453addaa537b7269312740f182c662d3"><td class="mdescLeft">&#160;</td><td class="mdescRight">test whether or not a pointer is not NULL  <a href="#a453addaa537b7269312740f182c662d3">More...</a><br /></td></tr>
<tr class="separator:a453addaa537b7269312740f182c662d3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a69b0d033bccc301fdd5a0cd9cd484c32"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a69b0d033bccc301fdd5a0cd9cd484c32">kct_assertEqualInt</a>(expected, actual)</td></tr>
<tr class="memdesc:a69b0d033bccc301fdd5a0cd9cd484c32"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if 2 integer values are equal. If not, send an error.  <a href="#a69b0d033bccc301fdd5a0cd9cd484c32">More...</a><br /></td></tr>
<tr class="separator:a69b0d033bccc301fdd5a0cd9cd484c32"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a638a32401f29c641c36fd0113b1d5d54"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a638a32401f29c641c36fd0113b1d5d54">kct_assertEqualIntMsg</a>(message, expected, actual)</td></tr>
<tr class="memdesc:a638a32401f29c641c36fd0113b1d5d54"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if 2 integer values are equal. If not, send an error.  <a href="#a638a32401f29c641c36fd0113b1d5d54">More...</a><br /></td></tr>
<tr class="separator:a638a32401f29c641c36fd0113b1d5d54"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a74ece761545f783064298ae259827892"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a74ece761545f783064298ae259827892">kct_assertNotEqualIntMsg</a>(message, expected, actual)</td></tr>
<tr class="memdesc:a74ece761545f783064298ae259827892"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if 2 integer values are not equal. If not, send an error.  <a href="#a74ece761545f783064298ae259827892">More...</a><br /></td></tr>
<tr class="separator:a74ece761545f783064298ae259827892"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae9b8d323c72c3b55a5048b64fca6291a"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#ae9b8d323c72c3b55a5048b64fca6291a">kct_assertNotEqualInt</a>(message, expected, actual)</td></tr>
<tr class="memdesc:ae9b8d323c72c3b55a5048b64fca6291a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if 2 integer values are not equal. If not, send an error.  <a href="#ae9b8d323c72c3b55a5048b64fca6291a">More...</a><br /></td></tr>
<tr class="separator:ae9b8d323c72c3b55a5048b64fca6291a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4fb6019e3502db5e5469766304128cd3"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a4fb6019e3502db5e5469766304128cd3">kct_assertEqualFloatMsg</a>(message, expected, actual)</td></tr>
<tr class="memdesc:a4fb6019e3502db5e5469766304128cd3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if 2 float values are not equal. If not, send an error.  <a href="#a4fb6019e3502db5e5469766304128cd3">More...</a><br /></td></tr>
<tr class="separator:a4fb6019e3502db5e5469766304128cd3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8c84ee7ffad95323e1504769aa320188"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a8c84ee7ffad95323e1504769aa320188">kct_assertNotEqualFloatMsg</a>(message, expected, actual)</td></tr>
<tr class="memdesc:a8c84ee7ffad95323e1504769aa320188"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if 2 float values are not equal. If not, send an error.  <a href="#a8c84ee7ffad95323e1504769aa320188">More...</a><br /></td></tr>
<tr class="separator:a8c84ee7ffad95323e1504769aa320188"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a812856cb26292426b3a484c716f82b19"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a812856cb26292426b3a484c716f82b19">kct_assertEqualArrayPrimitiveMsg</a>(message, type, conversion, expectedlength, expected, actual)</td></tr>
<tr class="memdesc:a812856cb26292426b3a484c716f82b19"><td class="mdescLeft">&#160;</td><td class="mdescRight">Check if 2 primitive array are equal. If not, sends an error.  <a href="#a812856cb26292426b3a484c716f82b19">More...</a><br /></td></tr>
<tr class="separator:a812856cb26292426b3a484c716f82b19"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1f7fb57006161a6056a0f8ca55181599"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a1f7fb57006161a6056a0f8ca55181599">kct_assertExtremisMsg</a>(optmessage, type, conversion, lowerbound, upperbound, lowin, upin, actual)</td></tr>
<tr class="memdesc:a1f7fb57006161a6056a0f8ca55181599"><td class="mdescLeft">&#160;</td><td class="mdescRight">checks if a value is in a given interval  <a href="#a1f7fb57006161a6056a0f8ca55181599">More...</a><br /></td></tr>
<tr class="separator:a1f7fb57006161a6056a0f8ca55181599"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0871daf80ad3af568bac7e0502c17205"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="KoldarCTester_8h.html#a0871daf80ad3af568bac7e0502c17205">kct_assertExtremis</a>(type, conversion, lowerbound, upperbound, lowin, upin, actual)</td></tr>
<tr class="memdesc:a0871daf80ad3af568bac7e0502c17205"><td class="mdescLeft">&#160;</td><td class="mdescRight">checks if a value is in a given interval  <a href="#a0871daf80ad3af568bac7e0502c17205">More...</a><br /></td></tr>
<tr class="separator:a0871daf80ad3af568bac7e0502c17205"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Macro Definition Documentation</h2>
<a class="anchor" id="a5e05020cd2cbf6ef54e4abb4c5d3ca57"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_addTest</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">function</td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>adds a new function in the test list </p>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>function has already been defined; </li>
<li>function must have no formal parameters; </li>
<li>function must return a void type; </li>
</ul>
</dd></dl>
<dl class="section post"><dt>Postcondition</dt><dd><ul>
<li>the function is inside the test list</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">function</td><td>(of type TestFunction) the function to include in the test list; </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a8b21af1302fae84b59f07b2b8964a64e"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_addTestImproved</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">function, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">torun&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>adds a new function in the test list </p>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>function has already been defined; </li>
<li>function must have no formal parameters; </li>
<li>function must return a void type; </li>
</ul>
</dd></dl>
<dl class="section post"><dt>Postcondition</dt><dd><ul>
<li>the function is inside the test list</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">function</td><td>(of type TestFunction) the function to include in the test list; </td></tr>
    <tr><td class="paramname">torun</td><td>(of type bool) TRUE is you want to actually run the test, FALSE if you want to include it in the list but you want to skip it </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ab47b71b14664ccf62a03056bf6afd299"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertCondition</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">condition</td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>end the test as a failure if the condition is <b>not</b> met </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">condition</td><td>represents the condition to be tested </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ab8d7d3073507383a0ab0913ebdce4a10"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertConditionMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">condition&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>end the test as a failure if the condition IS <b>not</b> met </p>
<p>In addition to end the test if condition is <b>not</b> met, this function will display an error message.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents the error message to be display if the condition is not met </td></tr>
    <tr><td class="paramname">condition</td><td>represents the condition to be test </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a812856cb26292426b3a484c716f82b19"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertEqualArrayPrimitiveMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">conversion, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expectedlength, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Check if 2 primitive array are equal. If not, sends an error. </p>
<p>A primitive array is an array whose cell contain data of a primitive type. A type is considered primitive if it is of type such as: </p><ul>
<li>int [signed or unsigned]; </li>
<li>long [signed or unsigned]; </li>
<li>short [signed or unsigned]; </li>
<li>char [signed or unsigned]; </li>
<li>float; </li>
<li>double; </li>
<li>bool; </li>
<li>pointer.</li>
</ul>
<p>The function starts with the first value inside the array and, checking one pair (one value from expected the other from actual) after another, checks if the 2 array expected and actual are equal. </p><dl class="section note"><dt>Note</dt><dd>The function checks the equality of the 2 array based only on expected array. The major consequence i that 2 array might be equal even if the lengths are different! For example these 2 array are equal for this function: <pre class="fragment">*       expected={1,2,3,4,5} (length: 5)
*       actual={1,2,3,4,5,6}
*       1==1, 2==2, 3==3, 4==4, 5==5
*  </pre> This happens because we don't know the length of the actual array. Note that the viceversa is <b>probably</b> <b>marked</b> as "different": <pre class="fragment">*       expected={1,2,3,4,5,6}
*       actual={1,2,3,4,5}
*       1==1, 2==2, 3==3, 4==4, 5==5, 6==random data (probably wrong)
*  </pre></dd></dl>
<p>The function checks if 2 array are equal (starting from the first value inside the array till the last one). If they are, nothing will happen. If not, the 2 values differents are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>string "position: ";</li>
<li>index where the 2 array differs;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected value at the index converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual value at the index converted into string;</li>
</ol>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">message</td><td>(of type char*) the optional message to show if the 2 array differs </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">type</td><td>the type of the cells owned by "expected" and "actual" array </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">conversion</td><td>(of type char*) how the type should be converted in string. Values accepted are all those accepted by printf, such as d, %1.3f %0x ex cetera. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">expectedlength</td><td>(of type int) represent the length of the array "expected" </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">expected</td><td>(of type type[]) the array expected by the assertion </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">actual</td><td>(of type type[]) the array got by the user. It must be checked against the array "expected" </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a4fb6019e3502db5e5469766304128cd3"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertEqualFloatMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks if 2 float values are not equal. If not, send an error. </p>
<p>The function checks if 2 integer are equal. If they are, nothing will happen. If not, the 2 values are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected parameter converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual parameter converted into string;</li>
</ol>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>message is of type char* (or a string); </li>
<li>expected is a value of type float; </li>
<li>actual is a value of type float;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents a custom message to prepend to the error message; </td></tr>
    <tr><td class="paramname">expected</td><td>(of type float) the value that the developer expects to get; </td></tr>
    <tr><td class="paramname">actual</td><td>(of type float) the very value received </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a69b0d033bccc301fdd5a0cd9cd484c32"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertEqualInt</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks if 2 integer values are equal. If not, send an error. </p>
<p>The function checks if 2 integer are equal. If they are, nothing will happen. If not, the 2 values are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected parameter converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual parameter converted into string;</li>
</ol>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>expected is a value of type int; </li>
<li>actual is a value of type int;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">expected</td><td>(type int) the value that the developer expects to get; </td></tr>
    <tr><td class="paramname">actual</td><td>(type int) the very value received </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a638a32401f29c641c36fd0113b1d5d54"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertEqualIntMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks if 2 integer values are equal. If not, send an error. </p>
<p>The function checks if 2 integer are equal. If they are, nothing will happen. If not, the 2 values are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected parameter converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual parameter converted into string;</li>
</ol>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>message is of type char* (or a string); </li>
<li>expected is a value of type int; </li>
<li>actual is a value of type int;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents a custom message to prepend to the error message; </td></tr>
    <tr><td class="paramname">expected</td><td>(of type int) the value that the developer expects to get; </td></tr>
    <tr><td class="paramname">actual</td><td>(of type int) the very value received </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a7c6235260c2f0889936b8edda762db19"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertEqualPrimitiveMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">conversion, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks if 2 simple values are equal. If not, send an error. </p>
<p>The function checks if 2 data are equal. If they are, nothing will happen. If not, the 2 values are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected parameter converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual parameter converted into string;</li>
</ol>
<p>The function can manage only simple data: </p><ul>
<li>int; </li>
<li>short; </li>
<li>long; </li>
<li>float; </li>
<li>double; </li>
<li>unsigned variations; </li>
<li>pointer variations (check the very pointers, not the structure pointed by them); </li>
<li>enumerations;</li>
</ul>
<dl class="section warning"><dt>Warning</dt><dd>While string and structure can be inserted as values to be checked, the function can't compare them with ease. If you have to compare strings or structures, please use <a class="el" href="KoldarCTester_8h.html#a0ce5dbaf8cd2f67f866855677b9dffa3" title="tests if 2 strings are equal ">kct_assertEqualStrMsg()</a> or PKCTM_ASSERTSTRUCTEQUAL</dd></dl>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>message is of type char* (or a string); </li>
<li>type is a simple type; </li>
<li>conversion is a formatter string, like "%d"; </li>
<li>expected is a value of type type; </li>
<li>actual is a value of type type;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents a custom message to prepend to the error message; </td></tr>
    <tr><td class="paramname">type</td><td>represents the type of expected and actual values (for example "unsigned long", "int" or "double"); </td></tr>
    <tr><td class="paramname">conversion</td><td>(of type char*) represents the formatter string used to format the stirng representations of expected and actual; </td></tr>
    <tr><td class="paramname">expected</td><td>(of type type) the value that the developer expects to get; </td></tr>
    <tr><td class="paramname">actual</td><td>(of type type) the very value received </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a8438378dbf37f64bd50cc68b6c698dc1"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertEqualPtrMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks if 2 pointers values are equal. If not, send an error. </p>
<p>The function checks if 2 pointers are equal. If they are, nothing will happen. If not, the 2 values are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected parameter converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual parameter converted into string;</li>
</ol>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>message is of type char* (or a string); </li>
<li>expected is a value of type void* (or a relative of it); </li>
<li>actual is a value of type void* (or a relative of it);</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents a custom message to prepend to the error message; </td></tr>
    <tr><td class="paramname">expected</td><td>(of type void*) the value that the developer expects to get; </td></tr>
    <tr><td class="paramname">actual</td><td>(of type void*) the very value received </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a7ca6642a5313ed8f901d01503a41d971"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertEqualStr</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>tests if 2 strings are equal </p>
<p>The macro tests wether or not 2 strings are equal: if they are, nothing will happen; otherwise an error will be generated.</p>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>expected is not NULL; </li>
<li>expected is of type char*; </li>
<li>actual is not NULL; </li>
<li>actual is of type char*;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">expected</td><td>the string that should be returned from the funciton under test; </td></tr>
    <tr><td class="paramname">actual</td><td>the string that is actually returned by the function under test; </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a0ce5dbaf8cd2f67f866855677b9dffa3"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertEqualStrMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">optmessage, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>tests if 2 strings are equal </p>
<p>The macro tests wether or not 2 strings are equal: if they are, nothing will happen; otherwise an error will be generated.</p>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>optmessage is not NULL; </li>
<li>optmessage is of type char*; </li>
<li>expected is not NULL; </li>
<li>expected is of type char*; </li>
<li>actual is not NULL; </li>
<li>actual is of type char*;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">optmessage</td><td>an optional message written by the developer holding useful information about this error </td></tr>
    <tr><td class="paramname">expected</td><td>the string that should be returned from the funciton under test; </td></tr>
    <tr><td class="paramname">actual</td><td>the string that is actually returned by the function under test; </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="af768219fd2cb4519ca0e547289ea8f07"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertEqualStructMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">toStringFunction, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">compareFunction, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks if 2 structured data are equal. If not, send an error. </p>
<p>The function checks if 2 structure data are equal. If they are, nothing will happen. If not, the 2 values are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected parameter converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual parameter converted into string;</li>
</ol>
<p>The function can easily manage structure data (typedef struct). To do so, however, it needs 2 functions: </p><ul>
<li>a compare function: this function takes 2 structure value of the same type and checks if they are equal; if they are, the function returns 0, otherwise it returns a non zero value. Note that the function can be much complex than a equal/different function: like strcmp(), it might returns a negative number if the first struct has a less value than the second and/or a positive number if the first structure has a greater value than the second one. The important stuff is that it returns 0 if the 2 given structs are equal. </li>
<li>a string conversion functions: the function has to take only one parameter, the structure to stringify and must return a char*. Moreover, <b>it must allocate a new string</b>: this is mandatory because the function will automatically free the char pointer returned by the function.</li>
</ul>
<dl class="section warning"><dt>Warning</dt><dd>{While primitive types can be inserted as values to be checked, the function can't compare them with ease. If you have to compare strings or structures, please use PKCTM_ASSERTINTEQUAL or similar}</dd></dl>
<p>An example of the use of this function: </p><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;typedef struct Point {</div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;   int x;</div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;   int y;</div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;} Point;</div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;</div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;char* Point2String(Point p){</div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;   char* buffer=malloc(100);</div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;   sprintf(buffer,&quot;(%d %d)&quot;,p.x,p.y);</div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;   return buffer;</div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;}</div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;</div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;int comparePoints(Point p1,Point p2){</div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;   if (p1.x!=p2.x){</div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;           return 1;</div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;   }</div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;   if (p1.y!=p2.y){</div>
<div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;           return 1;</div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;   }</div>
<div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;   return 0;</div>
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;}</div>
<div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;</div>
<div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160;void testOK(){</div>
<div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;   Point px;</div>
<div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;   Point py;</div>
<div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;   px.x=5;</div>
<div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160;   px.y=4;</div>
<div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;   py.x=5;</div>
<div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;   py.y=5;</div>
<div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160;   kct_assertEqualStructMsg(</div>
<div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;           &quot;the 2 points are different!&quot;,</div>
<div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;           Point,</div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;           Point2String,</div>
<div class="line"><a name="l00033"></a><span class="lineno">   33</span>&#160;           comparePoints,</div>
<div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160;           px,</div>
<div class="line"><a name="l00035"></a><span class="lineno">   35</span>&#160;           py);</div>
<div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;}</div>
<div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;</div>
<div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;int main(){</div>
<div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160;   kct_addTest(testOK);</div>
<div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;   kct_runAllTest(stdout);</div>
<div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;   return 0;</div>
<div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160;}</div>
</div><!-- fragment --><dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>message is of type char* (or a string); </li>
<li>type is a struct type; </li>
<li>toStringFunction is a name of a declared function; </li>
<li>toStringFunction takes only one parameter of type "type"; </li>
<li>toStringFunction return a char*; </li>
<li>toStringFunction allocates a new string in the heap representing the struct given; </li>
<li>compareFunction is a name of a declared function; </li>
<li>compareFunction takes only 2 paramters of type "type"; </li>
<li>compareFunction returns 0 or another value; </li>
<li>compareFunction must return 0 if the 2 values are equal; </li>
<li>compareFunction must return any other value beside 0 if the 2 values are different; </li>
<li>expected is a value of type type; </li>
<li>actual is a value of type type;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents a custom message to prepend to the error message; </td></tr>
    <tr><td class="paramname">type</td><td>represents the type of expected and actual values and the type of the parameters of the functions toStringFunction and compareFunction; </td></tr>
    <tr><td class="paramname">toStringFunction</td><td>represents the name </td></tr>
    <tr><td class="paramname">compareFunction</td><td>represents the function used to compare the structure of type "type" </td></tr>
    <tr><td class="paramname">expected</td><td>(of type type) the value that the developer expects to get; </td></tr>
    <tr><td class="paramname">actual</td><td>(of type type) the very value received </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a0871daf80ad3af568bac7e0502c17205"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertExtremis</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">conversion, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">lowerbound, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">upperbound, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">lowin, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">upin, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>checks if a value is in a given interval </p>
<p>The assertion allows you to check if a value (integer of float it doesn't matter) is inside a certain interval. The macro supports all the type of interval:</p>
<p>-* both interval inf and sup are <b>not</b> included in the interval itself: for example 5 is not in the interval <img class="formulaInl" alt="$]3;5[$" src="form_0.png"/> -* only the interval inf is included in the interval: for example 5 is in the interval <img class="formulaInl" alt="$[5;7[$" src="form_1.png"/> -* only the interval sup is cinluded in the interval: for example 5 is in the interval <img class="formulaInl" alt="$]3;5]$" src="form_2.png"/> -* both interval inf and sup are included in the interval: for example 5 is in the interval <img class="formulaInl" alt="$[3;5]$" src="form_3.png"/></p>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>lowerbound is an numeric type (integer, float, signed, unsigned); </li>
<li>upperbound is an numeric type (integer, float, signed, unsigned); </li>
<li>actualbound is an numeric type(integer, float, signed, unsigned); </li>
<li>lowin is a bool; </li>
<li>upin is a bool; </li>
<li>conversion is a fprintf compatible format expression (like d, lu or %2.6f); <pre class="fragment">The function easily accepts even randomic funcitions: the macro will behave
correctly even if you code:
</pre> <div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;kct_assertExtremis(int,&quot;%d&quot;,3,5,true,true,rand()%6); //wrong way to do it</div>
</div><!-- fragment --></li>
</ul>
If you are worry about the behaviour, however, you can always do like this: <div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;int a=rand()%6;</div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;kct_assertExtremis(int,&quot;%d&quot;,3,5,true,true,a); //correct way to do it</div>
</div><!-- fragment --></dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">type</td><td>the most general type of the number used in the interval. For example if lowerbound and actual are "int" but upperbound is a "double" the type should be set to "double". If you uncertain of what type you want to do "double" should be a appropriate choice. </td></tr>
    <tr><td class="paramname">conversion</td><td>the stirng representing how to correctly convert the number into a string. Values accepted are all those accepted by printf, such as d, f, %04d, %3.4f, lu ex cetera. </td></tr>
    <tr><td class="paramname">lowerbound</td><td>the inf of interval </td></tr>
    <tr><td class="paramname">upperbound</td><td>the sup of the interval </td></tr>
    <tr><td class="paramname">lowin</td><td>TRUE if the inf is included in the interval </td></tr>
    <tr><td class="paramname">upin</td><td>TRUE if the sup is included in the interval </td></tr>
    <tr><td class="paramname">actual</td><td>the value to check if is contained between lowerbound and upperbound </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a1f7fb57006161a6056a0f8ca55181599"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertExtremisMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">optmessage, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">conversion, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">lowerbound, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">upperbound, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">lowin, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">upin, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>checks if a value is in a given interval </p>
<p>The assertion allows you to check if a value (integer of float it doesn't matter) is inside a certain interval. The macro supports all the type of interval:</p>
<p>-* both interval inf and sup are <b>not</b> included in the interval itself: for example 5 is not in the interval <img class="formulaInl" alt="$]3;5[$" src="form_0.png"/> -* only the interval inf is included in the interval: for example 5 is in the interval <img class="formulaInl" alt="$[5;7[$" src="form_1.png"/> -* only the interval sup is cinluded in the interval: for example 5 is in the interval <img class="formulaInl" alt="$]3;5]$" src="form_2.png"/> -* both interval inf and sup are included in the interval: for example 5 is in the interval <img class="formulaInl" alt="$[3;5]$" src="form_3.png"/></p>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>lowerbound is an numeric type (integer, float, signed, unsigned); </li>
<li>upperbound is an numeric type (integer, float, signed, unsigned); </li>
<li>actualbound is an numeric type(integer, float, signed, unsigned); </li>
<li>lowin is a bool; </li>
<li>upin is a bool; </li>
<li>optmessage is a char*; </li>
<li>conversion is a fprintf compatible format expression (like d, lu or %2.6f); <pre class="fragment">The function easily accepts even randomic funcitions: the macro will behave
correctly even if you code:
</pre> <div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;kct_assertExtremis(&quot;randomic numbers&quot;,3,5,true,true,rand()%6); //wrong way to do it</div>
</div><!-- fragment --></li>
</ul>
If you are worry about the behaviour, however, you can always do like this: <div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;int a=rand()%6;</div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;kct_assertExtremis(&quot;randomic numbers&quot;,int,&quot;%d&quot;,3,5,true,true,a); //correct way to do it</div>
</div><!-- fragment --></dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">optmessage</td><td>(of type char*) the optional message to show if actual is not in the interval useful to developr to carry additional information </td></tr>
    <tr><td class="paramname">type</td><td>the most general type of the number used in the interval. For example if lowerbound and actual are "int" but upperbound is a "double" the type should be set to "double". If you uncertain of what type you want to do "double" should be a appropriate choice. </td></tr>
    <tr><td class="paramname">conversion</td><td>the stirng representing how to correctly convert the number into a string. Values accepted are all those accepted by printf, such as d, f, %04d, %3.4f, lu ex cetera. </td></tr>
    <tr><td class="paramname">lowerbound</td><td>(of type "type") the inf of interval </td></tr>
    <tr><td class="paramname">upperbound</td><td>(of type "type") the sup of the interval </td></tr>
    <tr><td class="paramname">lowin</td><td>(of type bool) TRUE if the inf is included in the interval </td></tr>
    <tr><td class="paramname">upin</td><td>(of type bool) TRUE if the sup is included in the interval </td></tr>
    <tr><td class="paramname">actual</td><td>(or type "type") the value to check if is contained between lowerbound and upperbound </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ab4e6c61583ca8ac8951757b691081cdf"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertIsNotNull</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">pointer</td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>test whether or not a pointer is NULL </p>
<p>The assertion checks if the pointer passed as parameter is NULL or not. Nothing will happen if pointer is a value different from 0.</p>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>pointer is void* typed (or a relative of it);</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">pointer</td><td>(of type void*) the pointer to test </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a5264879a5a7bec99330e05bbc284460c"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertIsNotNullMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">pointer&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>test whether or not a pointer is NULL </p>
<p>The assertion checks if the pointer passed as parameter is NULL or not. Nothing will happen if pointer is a value different from 0. The string message will be shown if the pointer is 0.</p>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>pointer is void* typed (or a relative of it);</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents the message to be shown if the assertion fails </td></tr>
    <tr><td class="paramname">pointer</td><td>(of type void*) the pointer to test </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a336d48b62a9bb572ac9bdad71f180fdf"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertIsNull</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">pointer</td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>test whether or not a pointer is not NULL </p>
<p>The assertion checks if the pointer passed as parameter is not NULL. Nothing will happen if pointer is a value equal from 0.</p>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>pointer is void* typed (or a relative of it);</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">pointer</td><td>(of type void*) the pointer to test </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a453addaa537b7269312740f182c662d3"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertIsNullMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">pointer&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>test whether or not a pointer is not NULL </p>
<p>The assertion checks if the pointer passed as parameter is not NULL. Nothing will happen if pointer is a value equal from 0. A message will be shown if the pointer is not NULL.</p>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>pointer is void* typed (or a relative of it); </li>
<li>message must be char* typed;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">pointer</td><td>(of type void*) the pointer to test </td></tr>
    <tr><td class="paramname">message</td><td>(of type char*) the message to show if the pointer is not NULL </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a97bd5c75a68868a4e449fa6d2abd7bd8"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertNotCondition</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">condition</td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>end the test as a failure if the condition is met </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">condition</td><td>represents the condition to be tested </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ac1eb638d5f665bf8b99147c08db85788"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertNotConditionMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">condition&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>end the test as a failure if the condition is met </p>
<p>In addition to end the test if condition is met, this function will display an error message.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents the error message to be display if the condition is not met </td></tr>
    <tr><td class="paramname">condition</td><td>represents the condition to be test </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a8c84ee7ffad95323e1504769aa320188"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertNotEqualFloatMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks if 2 float values are not equal. If not, send an error. </p>
<p>The function checks if 2 float are different. If they are, nothing will happen. If not, the 2 values are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected parameter converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual parameter converted into string;</li>
</ol>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>message is of type char* (or a string); </li>
<li>expected is a value of type float; </li>
<li>actual is a value of type float;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents a custom message to prepend to the error message; </td></tr>
    <tr><td class="paramname">expected</td><td>(of type float) the value that the developer expects to get; </td></tr>
    <tr><td class="paramname">actual</td><td>(of type float) the very value received </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ae9b8d323c72c3b55a5048b64fca6291a"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertNotEqualInt</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks if 2 integer values are not equal. If not, send an error. </p>
<p>The function checks if 2 integer are different. If they are, nothing will happen. If not, the 2 values are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected parameter converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual parameter converted into string;</li>
</ol>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>expected is a value of type int; </li>
<li>actual is a value of type int;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) the message to be shown if the assertion fails </td></tr>
    <tr><td class="paramname">expected</td><td>(of type int) the value that the developer expects to get; </td></tr>
    <tr><td class="paramname">actual</td><td>(of type int) the very value received </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a74ece761545f783064298ae259827892"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertNotEqualIntMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks if 2 integer values are not equal. If not, send an error. </p>
<p>The function checks if 2 integer are different. If they are, nothing will happen. If not, the 2 values are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected parameter converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual parameter converted into string;</li>
</ol>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>message is of type char* (or a string); </li>
<li>expected is a value of type int; </li>
<li>actual is a value of type int;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents a custom message to prepend to the error message; </td></tr>
    <tr><td class="paramname">expected</td><td>(of type int) the value that the developer expects to get; </td></tr>
    <tr><td class="paramname">actual</td><td>(of type int) the very value received </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a8b6f1bb142ced3a6d64d6cb08889bf77"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertNotEqualPrimitiveMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">conversion, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks if 2 simple values are not equal. If not, send an error. </p>
<p>The function checks if 2 data are different. If they are, nothing will happen. If not, the 2 values are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected parameter converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual parameter converted into string;</li>
</ol>
<p>The function can manage only simple data: they include: </p><ul>
<li>int; </li>
<li>short; </li>
<li>long; </li>
<li>float; </li>
<li>double; </li>
<li>unsigned variations; </li>
<li>pointer variations (check the very pointers, not the structure pointed by them); </li>
<li>enumerations;</li>
</ul>
<dl class="section warning"><dt>Warning</dt><dd>While string and structure can be inserted as values to be checked, the function can't compare them with ease. If you have to compare strings or structures, please use <a class="el" href="KoldarCTester_8h.html#a0ce5dbaf8cd2f67f866855677b9dffa3" title="tests if 2 strings are equal ">kct_assertEqualStrMsg()</a> or PKCTM_ASSERTSTRUCTEQUAL</dd></dl>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>message is of type char* (or a string); </li>
<li>type is a simple type; </li>
<li>conversion is a formatter string, like "%d"; </li>
<li>expected is a value of type type; </li>
<li>actual is a value of type type;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents a custom message to prepend to the error message; </td></tr>
    <tr><td class="paramname">type</td><td>represents the type of expected and actual values (for example "unsigned long", "int" or "double"); </td></tr>
    <tr><td class="paramname">conversion</td><td>(of type char*) represents the formatter string used to format the string representations of expected and actual; </td></tr>
    <tr><td class="paramname">expected</td><td>(of type type) the value that the developer expects to get; </td></tr>
    <tr><td class="paramname">actual</td><td>(of type type) the very value received </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="afb48d44aa30b8baab5acea013b5a13ea"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertNotEqualPtrMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks if 2 pointer values are not equal. If not, send an error. </p>
<p>The function checks if 2 pointers are different. If they are, nothing will happen. If not, the 2 values are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected parameter converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual parameter converted into string;</li>
</ol>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>message is of type char* (or a string); </li>
<li>expected is a value of type void* (or a relative of it); </li>
<li>actual is a value of type void* (or a relative of it);</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents a custom message to prepend to the error message; </td></tr>
    <tr><td class="paramname">expected</td><td>(of type void*) the value that the developer expects to get; </td></tr>
    <tr><td class="paramname">actual</td><td>(of type void*) the very value received </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a42cb8f2498583663010902a2646b8d9d"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_assertNotEqualStructMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">type, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">toStringFunction, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">compareFunction, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">expected, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">actual&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks if 2 structured data are different. If not, send an error. </p>
<p>The function checks if 2 structure data are not equal. If they are, nothing will happen. If not, the 2 values are converted in string and a error message is thrown at the user. The error is so composed:</p><ol type="1">
<li>message parameter;</li>
<li>KCT_ERRORMESSAGE_EXPECTED;</li>
<li>expected parameter converted into string;</li>
<li>KCT_ERRORMESSAGE_ACTUAL;</li>
<li>actual parameter converted into string;</li>
</ol>
<p>The function can easily manage structure data (typedef struct). To do so, however, it needs 2 functions: </p><ul>
<li>a compare function: this function takes 2 structure value of the same type and checks if they are equal; if they are, the function returns 0, otherwise it returns a non zero value. Note that the function can be much complex than a equal/different function: like strcmp(), it might returns a negative number if the first struct has a less value than the second and/or a positive number if the first structure has a greater value than the second one. The important stuff is that it returns 0 if the 2 given structs are equal. </li>
<li>a string conversion functions: the function has to take only one parameter, the structure to stringify and must return a char*. Moreover, <b>it must allocate a new string</b>: this is mandatory because the function will automatically free the char pointer returned by the function.</li>
</ul>
<dl class="section warning"><dt>Warning</dt><dd>{While primitive types can be inserted as values to be checked, the function can't compare them with ease. If you have to compare strings or structures, please use PKCTM_ASSERTINTEQUAL or similar}</dd></dl>
<p>An example of the use of this function: </p><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;typedef struct Point {</div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;   int x;</div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;   int y;</div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;} Point;</div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;</div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;char* Point2String(Point p){</div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;   char* buffer=malloc(100);</div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;   sprintf(buffer,&quot;(%d %d)&quot;,p.x,p.y);</div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;   return buffer;</div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;}</div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;</div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;int comparePoints(Point p1,Point p2){</div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;   if (p1.x!=p2.x){</div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;           return 1;</div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;   }</div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;   if (p1.y!=p2.y){</div>
<div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;           return 1;</div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;   }</div>
<div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;   return 0;</div>
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;}</div>
<div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;</div>
<div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160;void testOK(){</div>
<div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;   Point px;</div>
<div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;   Point py;</div>
<div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;   px.x=5;</div>
<div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160;   px.y=4;</div>
<div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;   py.x=5;</div>
<div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;   py.y=5;</div>
<div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160;   kct_assertNotEqualStructMsg(</div>
<div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;           &quot;the 2 points are different!&quot;,</div>
<div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;           Point,</div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;           Point2String,</div>
<div class="line"><a name="l00033"></a><span class="lineno">   33</span>&#160;           comparePoints,</div>
<div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160;           px,</div>
<div class="line"><a name="l00035"></a><span class="lineno">   35</span>&#160;           py);</div>
<div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;}</div>
<div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;</div>
<div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;int main(){</div>
<div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160;   kct_addTest(testOK);</div>
<div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;   kct_runAllTest(stdout);</div>
<div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;   return 0;</div>
<div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160;}</div>
</div><!-- fragment --><dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>message is of type char* (or a string); </li>
<li>type is a struct type; </li>
<li>toStringFunction is a name of a declared function; </li>
<li>toStringFunction takes only one parameter of type "type"; </li>
<li>toStringFunction return a char*; </li>
<li>toStringFunction allocates a new string in the heap representing the struct given; </li>
<li>compareFunction is a name of a declared function; </li>
<li>compareFunction takes only 2 paramters of type "type"; </li>
<li>compareFunction returns 0 or another value; </li>
<li>compareFunction must return 0 if the 2 values are equal; </li>
<li>compareFunction must return any other value beside 0 if the 2 values are different; </li>
<li>expected is a value of type type; </li>
<li>actual is a value of type type;</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents a custom message to prepend to the error message; </td></tr>
    <tr><td class="paramname">type</td><td>represents the type of expected and actual values and the type of the parameters of the functions toStringFunction and compareFunction; </td></tr>
    <tr><td class="paramname">toStringFunction</td><td>represents the name </td></tr>
    <tr><td class="paramname">compareFunction</td><td>represents a function used to compare the 2 instances of type "type" expected and actual </td></tr>
    <tr><td class="paramname">expected</td><td>the value that the developer expects to get; </td></tr>
    <tr><td class="paramname">actual</td><td>the very value received </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a4c849806881e4b0a1db5d2ceb7f30fe8"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define KCT_ERRORMESSAGE_ACTUAL</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Represents the string to print before the actual value in the error message. </p>
<p>This macro allows you to change the default string that is printed out after the developer message in the event a test fails. This string will printed only when macro functions like kct_assertEqualXXXMsg() are called; the macro isn't influenting failMsg() or AssertCondMsg() assertion like!</p>
<p>If you want to change the default value, define KCT_CONTROLMACRO_ERRORMESSAGE_ACTUAL as your custom string, like in this example:</p>
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;#define KCT_CONTROLMACRO_ERRORMESSAGE_ACTUAL &quot;\nACTUAL VALUE&quot;</div>
</div><!-- fragment --><p>The default value is: "\nActual value:   ".</p>
<dl class="section warning"><dt>Warning</dt><dd>To enable this custom behaviour, define KCT_CONTROLMACRO_ERRORMESSAGE_ACTUAL <b>before</b> including KoldarCTester header. In alternative, you may compile your test suite with a "-D" flag enabled. The syntax of the error message is shown here:</dd></dl>
<p>!!!ERROR!!! userErrorMessage KCT_ERRORMESSAGE_EXPECTED value expected KCT_ERRORMESSAGE_ACTUAL actual value </p>

</div>
</div>
<a class="anchor" id="a03d95195bbcbf6bf52e6c163281efed8"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define KCT_ERRORMESSAGE_EXPECTED</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Represents the string to print before the expected value in the error message. </p>
<p>This macro allows you to change the default string that is printed out after the developer message in the event a test fails. This string will printed only when macro functions like kct_assertEqualXXXMsg() are called; the macro isn't influenting failMsg() or AssertCondMsg() assertions like!</p>
<p>If you want to change the default value, define KCT_CONTROLMACRO_ERRORMESSAGE_EXPECTED as your custom string, like in this example:</p>
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;#define KCT_CONTROLMACRO_ERRORMESSAGE_EXPECTED &quot;\nEXPECTED VALUE&quot;</div>
</div><!-- fragment --><p>The default value is: "\nExpected value: ".</p>
<dl class="section warning"><dt>Warning</dt><dd>To enable this custom behaviour, define KCT_CONTROLMACRO_ERRORMESSAGE_EXPECTED <b>before</b> including KoldarCTester header. In alternative, you may compile your test suite with a "-D" flag enabled.The syntax of the error message is shown here:</dd></dl>
<p>!!!ERROR!!! errorMessage KCT_ERRORMESSAGE_EXPECTED value expected KCT_ERRORMESSAGE_ACTUAL actual value </p>

</div>
</div>
<a class="anchor" id="a711828fbdf116ebd2722f9aa48916832"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_failMsg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">message</td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Terminate the test and set the result of it as a failure. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">message</td><td>(of type char*) represents the message to display just before the ending of the test. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a410bf9dc82153e2f88b61ea9e360ab40"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define kct_runAllTests</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">outputfile</td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>run all the test added to the test list. </p>
<p>The function run all the tests which has been added to the test list. You can add test function in the test list with the function <a class="el" href="KoldarCTester_8h.html#a5e05020cd2cbf6ef54e4abb4c5d3ca57" title="adds a new function in the test list ">kct_addTest()</a>. Not all the tests will be run, but onyly those tests which are appended with the flag "torun" set to "TRUE"</p>
<dl class="section pre"><dt>Precondition</dt><dd><ul>
<li>outputfile open in write mode </li>
</ul>
</dd></dl>
<dl class="section post"><dt>Postcondition</dt><dd><ul>
<li>test outcome is appended to the outputfile</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">outputfile</td><td>(of type FILE*) where to write the test outcome </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a07e3e0722765c92ee10a9942dbbf7efb"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define KCT_STRINGBUFFER</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>This macro allows you to change the default size of the buffer used to convert values into strings. The buffer is useful only in assertions like kct_assertEqualXXXMsg().</p>
<dl class="section note"><dt>Note</dt><dd>{The default value is 15}</dd></dl>
<p>For example, let assume you want to convert the number 1234567890123456789. Being this number much longer than 15 the header will stringify will wrongly. By defining this custom value, you can easily increase the buffer size, solving the problem.</p>
<dl class="section warning"><dt>Warning</dt><dd>To enable this custom behaviour, define KCT_CONTROLMACRO_STRINGBUFFER <b>before</b> including KoldarCTester header. In alternative, you may compile your test suite with a "-D" flag enabled. Represents the size of the buffer used to convert number (float or integer it doesn't matter) to strings. The constant is mainly used in the macros like PKCTM_ITOA or PKCTM_FTOA </dd></dl>

</div>
</div>
<a class="anchor" id="a5f792115dc3f1978a91f1071e2fdb9d2"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define KCT_TESTSEPARATOR</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Represents the string that separates 2 test function in the output. </p>
<p>This macro controls the string separator between 2 test function. The default one is the string "**************" Compile your test program with KCT_CONTROLMACRO_TESTSEPARATOR enabled to change the separator between test functions: </p><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;#define KCT_CONTROLMACRO_TESTSEPARATOR &quot;%%%%%%%%%%%%%%%%&quot;</div>
</div><!-- fragment --><div class="image">
<img src="image02.png" alt="image02.png"/>
</div>
<dl class="section warning"><dt>Warning</dt><dd>To enable this custom behaviour, define KCT_CONTROLMACRO_TESTSEPARATOR <b>before</b> including KoldarCTester header. In alternative, you may compile your test suite with a "-D" flag enabled. </dd></dl>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="dir_3b579af105d68949fc87077585f616df.html">macro</a></li><li class="navelem"><a class="el" href="KoldarCTester_8h.html">KoldarCTester.h</a></li>
    <li class="footer">Generated on Sat Aug 23 2014 20:58:19 for KoldarCtester by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.8 </li>
  </ul>
</div>
</body>
</html>
